package zl.applet.block;
//方格类
public class Box implements Cloneable
{
	//属性、是否是带颜色的方格
	private boolean isColor;

	public Box(){}
	public Box(boolean isColor)
	{
		//构造方法、为属性初始化
		this.isColor = isColor;
	}

	//封装属性
	public void setIsColor(boolean isColor)
	{
		this.isColor = isColor;
	}
	public boolean getIsColor()
	{
		return this.isColor;
	}

	//重写clone方法。以便克隆用
	public Object clone()
	{
		try
		{
			return (Box)super.clone();
		}
		catch (CloneNotSupportedException e)
		{
			e.printStackTrace();
		}
		return null;
	}
}